package com.tyk.bookstore.back.order.model.query;

import com.tyk.bookstore.back.common.core.model.constant.ValidConstant;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.*;
import lombok.Data;

/**
 * @author tyk
 * @description CneeAddressUpdateQuery
 */
@Data
public class CneeAddressUpdateQuery {

    @Schema(description = "ID")
    @NotNull
    @Min(1)
    private Long orderId;

    @Schema(description = "收件人姓名")
    @NotBlank
    @Size(min = 1, max = 16)
    private String cneeName;

    @Schema(description = "收件人电话")
    @NotBlank
    @Size(min = 11, max = 11)
    @Pattern(regexp = ValidConstant.PHONE_REGEXP)
    private String cneePhone;

    @Schema(description = "收件人所在区域ID")
    @NotNull
    @Min(1)
    private Long cneeAreaCode;

    @Schema(description = "收件人地址")
    @NotBlank
    @Size(min = 1, max = 48)
    private String cneeAddress;
}
